An animated and customised Pie chart
This goes in the documents header:
<script src="RGraph.common.core.js"></script>
<script src="RGraph.common.tooltips.js"></script>
<script src="RGraph.common.dynamic.js"></script>
<script src="RGraph.common.effects.js"></script>
<script src="RGraph.pie.js"></script>
Put this where you want the chart to show up:
<canvas id="cvs" width="480" height="250">
[No canvas support]
</canvas>
This is the code that generates the chart:
<script>
new RGraph.Pie({
id: 'cvs',
data: [1750, 6250],
options: {
strokestyle: 'white',
colors: ['#DDDF0D','#7798BF'],
linewidth: 3,
exploded: [15],
shadowOffsetx: 2,
shadowOffsety: 2,
shadowBlur: 5,
labels: ['Jerry'],
labelsSticksList: true,
labelsSticksUsecolors: false,
textColor: '#000',
textSize:12,
textAccessible: true
}
}).roundRobin();
</script>